package com.naizhuai.network.exception;

import com.google.gson.annotations.SerializedName;

/**
 * Created by lichenxi on 2017/5/18.
 */

public class ServerException extends RuntimeException {
    public static final int USER_NO_LOGIN=3005;
    public static final int USER_NOT_IN_COMPANY=6001;

    @SerializedName("errCode")
    private int code;
    @SerializedName("errMsg")
    private String msg;


    public ServerException(int code) {
        this(code,"");
    }
    public ServerException(int code, String msg) {
        super(msg);
        this.code = code;
        this.msg = msg;
    }

    public int getCode() {
        return code;
    }

    public String getMsg() {
        return msg;
    }

}
